<?
include('adminPage.php');
include('db_connect.php');

$query = "select userID, userName, userLogInName, userDept, userPhone, adminLevel from user";
$result = mysql_query($query);

echo "<table border=1>";
echo "<caption>USER LIST</caption>";
	echo "<td></td><td>No</td><td>Name</td><td>ID</td><td>Dept</td><td>Phone</td><td>AdminLevel</td>";
while($row = mysql_fetch_array($result, MYSQL_ASSOC)) {
	echo "<tr>";
	echo "<td><input type='checkbox' name='check' value='a'></td>";
	echo "<td>".$row['userID']."</td>";
	echo "<td>".$row['userName']."</td>";
	echo "<td>".$row['userLogInName']."</td>";
	echo "<td>".$row['userDept']."</td>"; 
	echo "<td>".$row['userPhone']."</td>";
	echo "<td>".$row['adminLevel']."</td>"; 
	echo "</tr>";
}
echo "</table>";

mysql_close($conn);
?>